package com.zhenwei.zscm.mappings;

import com.zhenwei.zscm.entity.OrderEntity;
import com.zhenwei.zscm.entity.VOrderStatisticByDateEntity;
import com.zhenwei.zscm.model.dto.order.OrderDTO;
import com.zhenwei.zscm.model.dto.order.OrderStatisticByDateDTO;
import com.zhenwei.zscm.model.vo.order.CreateOrderVO;
import org.mapstruct.Mapper;
import org.mapstruct.factory.Mappers;

@Mapper
public interface OrderMapping {
    OrderMapping INSTANCE = Mappers.getMapper(OrderMapping.class);

    OrderEntity vo2Entity(CreateOrderVO vo);
    OrderDTO entity2Dto(OrderEntity entity);

    OrderEntity dto2Entity(OrderDTO orderDTO);

    OrderStatisticByDateDTO entity2Dto(VOrderStatisticByDateEntity entity);
}
